home *** CD-ROM | disk | FTP | other *** search
- { This is the existing WRONG procedure ShortCutToKey from Menus:
-
- procedure ShortCutToKey(ShortCut: TShortCut; var Key: Word; var Shift: TShiftState);
- begin
- Key := Key and not (scShift + scCtrl + scAlt);
- Shift := [];
- if Key and scShift <> 0 then Include(Shift, ssShift);
- if Key and scCtrl <> 0 then Include(Shift, ssCtrl);
- if Key and scAlt <> 0 then Include(Shift, ssAlt);
- end;
-
- And this is how it should read: }
-
- procedure ShortCutToKey(ShortCut: TShortCut; var Key: Word; var Shift: TShiftState);
- begin
- Key := ShortCut and not (scShift + scCtrl + scAlt);
- Shift := [];
- if ShortCut and scShift <> 0 then Include(Shift, ssShift);
- if ShortCut and scCtrl <> 0 then Include(Shift, ssCtrl);
- if ShortCut and scAlt <> 0 then Include(Shift, ssAlt);
- end;